f = open("./lyric.txt",mode="r")
text = f.read().split()
word = set(text)
result = {}
for i in word:
    result[i]=text.count(i)

from wordcloud import WordCloud
# import matplotlib.pyplot as plt
a = WordCloud()
a.generate_from_frequencies(result)
# plt.figure()
# plt.imshow(a)
a.to_file("a.png")